package masterjava.reporting.client.model;

import com.extjs.gxt.ui.client.data.BaseModel;
import masterjava.reporting.shared.entity.TimestampData;

import java.util.Date;

/**
 * User: gkislin
 * Date: 7/19/11
 */
public class TimestampDataModel extends BaseModel {
    public static final String TIMESTAMP = "timestamp";
    public static final String VALUE = "value";

    private Date timestamp;
    private double value;

    public TimestampDataModel() {
    }

    public TimestampDataModel(TimestampData timestampData) {
        set(TIMESTAMP, timestampData.getTimestamp());
        set(VALUE, timestampData.getValue());
    }

    public Date getTimestamp() {
        return timestamp;
    }

    public double getValue() {
        return value;
    }
}
